package martial.arts.tracker

class Account {

    Long accountId
    String lastName
    String firstName
    String street
    String city
    String state
    Long zip
    Date dateCreated
    Date lastUpdated
    String email
    /*Student students
    Payment payments*/

    static hasMany = [students: Student, payments: Payment]

    String toString() {return "${accountId} - ${lastName}, ${firstName}" }

    static constraints = {
        accountId()
        lastName()
        firstName()
        street()
        city()
        state()
        zip()
        email(nullable: true)
    }
}
